﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using DevExpress.XtraEditors;

namespace SoufunData
{
    public partial class MainForm : DevExpress.XtraEditors.XtraForm
    {
        public MainForm()
        {
            InitializeComponent();
            this.Text = "搜房网数据库程序" + _clientVersion;
        }

        private string _clientVersion = "v1.01";

        //土地供应数据导入
        private void barButtonItem2_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            this.ShowImportExcelDataForm("土地供应数据导入");
        }


        //土地成交数据导入
        private void barButtonItem1_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            this.ShowImportExcelDataForm("土地成交数据导入");
        }

        //土地数据分析
        private void barButtonItem3_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            
        }




        private void ShowImportExcelDataForm(string title)
        {
            ImportExcelData importExcelData = new ImportExcelData();
            importExcelData.MdiParent = this;
            importExcelData.labelTitle = title;
            importExcelData.Show();
        }

        private void barBtnItem_ExToDbAdvertising_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZAdvertising form = new ExToDbZAdvertising();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbOpening_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZOpeningMonitor form = new ExToDbZOpeningMonitor();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbConstruction_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZConstruction form = new ExToDbZConstruction();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbProContract_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZProjectContract form = new ExToDbZProjectContract();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbProDetail_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZProjectDetail form = new ExToDbZProjectDetail();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbYuShou_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbZYuShouZheng form = new ExToDbZYuShouZheng();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_AdvertisingForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZAdvertisingForm form = new ZAdvertisingForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ConstructionForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZConstructionForm form = new ZConstructionForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_OpeningForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZOpeningMonitorForm form = new ZOpeningMonitorForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ProjectContractFrom_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZProjectContractForm form = new ZProjectContractForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_projectDetail_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZProjectDetailForm form = new ZProjectDetailForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ZYushouzhengForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ZYuShouZhengForm form = new ZYuShouZhengForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtodbBBasicinfoForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbBBasicInfo form = new ExToDbBBasicInfo();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbBPlanning_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbBBPlanningDesign form = new ExToDbBBPlanningDesign();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_BusinessManager_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbBBusinessManage form = new ExToDbBBusinessManage();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExtoDbSummarize_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbBBSummarize form = new ExToDbBBSummarize();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_BProjectListForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            BProjectListForm form = new BProjectListForm();
            form.MdiParent = this;
            form.Show();
        }

        private void MainForm_FormClosing(object sender, FormClosingEventArgs e)
        {
            if (XtraMessageBox.Show("是否确定退出？","提醒:",
                MessageBoxButtons.YesNo) == DialogResult.No)
            {
                e.Cancel = true;
            }
        }

        private void barButtonItem1_ItemClick_1(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbOfficeInfoForm form = new ExToDbOfficeInfoForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_OfficeInfoForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            OfficeProjectListForm form = new OfficeProjectListForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_ExcelToDbLandSupport_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbLandSupportForm form = new ExToDbLandSupportForm();
            form.MdiParent = this;
            form.Show();

        }

        private void barBtnItem_ExcelToDbLandTrans_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ExToDbLandTransaction form = new ExToDbLandTransaction();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_LandInfoListForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            LandInfoListForm form = new LandInfoListForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_LandStatisticsForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            LandStatisticsForm form = new LandStatisticsForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barButtonItem1_ItemClick_2(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            LandRankingsForm form = new LandRankingsForm();
            form.MdiParent = this;
            form.Show();
        }

        private void barBtnItem_landstatisticsRankForm_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            LandStatisticsRankingsForm form = new LandStatisticsRankingsForm();
            form.MdiParent = this;
            form.Show();
        }


    }
}